package com.crm.controller;

import com.crm.annotation.PassToken;
import com.crm.constant.dto.BaseFxResponse;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @version 1.0
 * @author: CRM_SYSTEM
 * @date: 2022/3/29 21:16
 * @Description:
 */
@RestController
public class TestController {

    @PassToken
    @GetMapping("/test/a")
    public BaseFxResponse<?> getTest(){
        return BaseFxResponse.success("2414");
    }

    @PassToken
    @GetMapping("/test/b")
    public BaseFxResponse<?> getTestb(){
        int i = 1 / 0;
        return BaseFxResponse.success("2414");
    }

    @PassToken
    @GetMapping("/test/c")
    public BaseFxResponse<?> getTestc(){
        return BaseFxResponse.failMsg("2414");
    }
}
